package com.ruoyi.system.api.service;

import com.alibaba.fastjson.JSONObject;
import com.ruoyi.system.api.ResponseWithData;
import com.ruoyi.system.api.domain.FseLocation;
import okhttp3.Response;

import java.sql.Date;
import java.util.List;
import java.util.Map;

public interface CcService {

    /**
     * 2.6获取TL名下工程师接口
     *
     * @param ServiceNoticeId
     * @param TeamleaderId
     * @param InterfaceType
     * @methodName: getEngineerByTL
     * @description: TODO
     * @return: com.ruoyi.system.api.ResponseWithData<?>
     * @author: shihx
     * @date: 2020/3/6 9:47
     **/
    public ResponseWithData<?> getEngineerByTL(String ServiceNoticeId, String TeamleaderId, String InterfaceType) throws Exception;

    /**
     * 2.7获取FSE型号技能接口
     *
     * @param ServiceNoticeId
     * @param TeamleaderId
     * @param InterfaceType
     * @param instrumentNo
     * @methodName: getFseSkill
     * @description: TODO
     * @return: com.ruoyi.system.api.ResponseWithData<?>
     * @author: shihx
     * @date: 2020/3/6 10:02
     **/
    public JSONObject getFseSkill(String ServiceNoticeId, String TeamleaderId, String InterfaceType, String instrumentNo) throws Exception;

    /**
     * 2.24 电话解决报告
     *
     * @param params
     * @return okhttp3.Response
     * @author yzg
     * @date 2020/3/6 10:08 上午
     */
    public String phoneSolveSubmithandle(Map<String, String> params);

    /**
     * 2.31 删除服务报告
     *
     * @param enginnerId 工程师id	必须
     * @param serviceNo  服务名称	必须
     * @param reportGuid App端生成唯一的	必须
     * @return String
     * @author yzg
     * @date 2020/3/6 10:35 上午
     */
    public String deleteServiceReport(Long enginnerId, String serviceNo, String reportGuid);

    /**
     * 2.19	服务关闭-2[安装验收报告]
     * 提交安装验收报告
     *
     * @param params
     * @return okhttp3.Response
     * @author yzg
     * @date 2020/3/7 10:34 上午
     */
    public String installReceivingReporthandle(Map<String, String> params);

    /**
     * 2.21	服务关闭-4[Error report]
     * 提交Error report
     *
     * @param params
     * @return string
     * @author yzg
     * @date 2020/3/7 10:49 上午
     */
    public String erroReporthandleerroReportInfo(Map<String, Object> params);

    /**
     * 2.22	服务关闭-5[Hot Account  report]
     * 提交Hot Account  report
     *
     * @param params
     * @return string
     * @author yzg
     * @date 2020/3/7 11:02 上午
     */
    public String accountReporthandle(Map<String, String> params);

    /**
     * 2.23	关闭ErrorReport/HT
     *
     * @param service_no  Service号
     * @param enginner_id 提交的工程师ID
     * @param report_guid 唯一主键
     * @param Report_type 报告类型  ER/HT
     * @return okhttp3.Response
     * @author yzg
     * @date 2020/3/7 11:07 上午
     */
    public Response closeServicehandle(String service_no, Long enginner_id, String report_guid, String Report_type);

    /**
     * 2.20	服务关闭-3 [安装质量报告]
     *
     * @param params
     * @return okhttp3.Response
     * @author yzg
     * @date 2020/3/7 11:19 上午
     */
    public String installqualityReporthandle(Map<String, Object> params);

    /**
     * 2.18	服务关闭-1[提交服务报告]
     *
     * @param params
     * @return okhttp3.Response
     * @author yzg
     * @date 2020/3/10 2:44 下午
     */
    public String serviceSubmithandle(Map<String, Object> params);

    /**
     * 2.2同步TL待指派服务信息接口
     *
     * @param timeStamp
     * @methodName: syncTLServiceData
     * @description: TODO
     * @return: okhttp3.Response
     * @author: shihx
     * @date: 2020/3/11 16:02
     **/
    public ResponseWithData<?> syncTLServiceData(Long timeStamp) throws Exception;

    /**
     * 2.27	同步基础数据接口
     *
     * @param tableName
     * @param engineerId
     * @return
     */
    public List getParamTables(String tableName, Long engineerId);

    /**
     * 2.27	同步基础数据接口（SyncTables.asmx/GetParamTablesErr 查询级联数据）
     *
     * @param tableName
     * @param engineerId
     * @return
     */
    public List selectCCDictWidthParent(String tableName, Long engineerId, String parentValue);

    /**
     * 2.27	同步基础数据接口
     *
     * @param tableName
     * @param engineerId
     * @return
     */
    public String getParamTables1(String tableName, Long engineerId);

    /**
     * 2.5TL设置仪器指定FSE
     *
     * @param teamleaderId
     * @param serviceNo
     * @param accoutfseId
     * @param instrumentId
     * @methodName: setPartAccountFSE
     * @description: TODO
     * @return: boolean
     * @author: shihx
     * @date: 2020/3/20 14:31
     **/
    public JSONObject setPartAccountFSE(String teamleaderId, String serviceNo, String accoutfseId, String instrumentId);

    /**
     * 2.17绑定仪器条码
     *
     * @param instrumentId
     * @param enginnerId
     * @param code
     * @methodName: BindDeviceInfo
     * @description: TODO
     * @return: okhttp3.Response
     * @author: shihx
     * @date: 2020/3/21 14:42
     **/
    public JSONObject BindDeviceInfo(String instrumentId, String enginnerId, String code);

    /**
     * 2.16信息修改申请
     *
     * @param enginnerId
     * @param serviceNo
     * @param remarks
     * @methodName: updateOrderInfo
     * @description: TODO
     * @return: com.alibaba.fastjson.JSONObject
     * @author: shihx
     * @date: 2020/3/21 15:39
     **/
    public JSONObject updateOrderInfo(String enginnerId, String serviceNo, String remarks);

    /**
     * 2.14接受服务
     *
     * @param enginnerId
     * @param serviceNo
     * @param expectTime
     * @param bespokeTime
     * @methodName: acceptService
     * @description: TODO
     * @return: com.alibaba.fastjson.JSONObject
     * @author: shihx
     * @date: 2020/3/23 19:45
     **/
    public JSONObject acceptService(String enginnerId, String serviceNo, String expectTime, String bespokeTime, String sendID, java.util.Date sendDate);

    /**
     * 4、服务费接口
     *
     * @param engineerId
     * @param bu
     * @param prov
     * @param city
     * @methodName: GetServiceCharge
     * @description: TODO
     * @return: okhttp3.Response
     * @author: shihx
     * @date: 2020/3/24 13:48
     **/
    public JSONObject GetServiceCharge(String engineerId, String bu, String prov, String city);


    /**
     * 2.53查询仪器数据
     *
     * @param CustomerName
     * @param serialNo
     * @param Div
     * @param bu
     * @methodName: getFseSkill
     * @description: TODO
     * @return: com.ruoyi.system.api.ResponseWithData<?>
     * @author: shihx
     * @date: 2020/3/6 10:02
     **/
    public JSONObject getInstrumentList(String CustomerName, String serialNo, String Div, String bu, String starttime, String endtime) throws Exception;

    /**
     * 关闭服务通知
     *
     * @param EnginnerId
     * @param serviceNo
     * @return
     * @throws Exception
     */
    public JSONObject closeNotice(String EnginnerId, String serviceNo, Long ServiceNoticeId) throws Exception;


    /**
     * 关闭服务通知
     *
     * @param EnginnerId
     * @param serviceNo
     * @return
     * @throws Exception
     */
    public JSONObject errorReportCloseNotice(String id, String EnginnerId, String serviceNo, String ServiceNoticeId, String reportType) throws Exception;

    /**
     * 2.27	同步基础数据接口(获取ErrorCode)
     *
     * @param EnginnerId
     * @return
     * @throws Exception
     */
    public List getErrorCode(Long EnginnerId) throws Exception;

    /**
     * 2.63	备件号查询Price及备件名称接口
     *
     * @param partCode
     * @return
     * @throws Exception
     */
    public JSONObject queryPriceByPartCode(String partCode) throws Exception;

    /**
     * 获取ErrorCode三级下拉
     *
     * @param parentValue
     * @param errCode
     * @methodName: getParamTablesErr
     * @description: TODO
     * @return: com.alibaba.fastjson.JSONObject
     * @author: shihx
     * @date: 2020-04-10 10:30
     **/
    public ResponseWithData<?> getParamTablesErr(String parentValue, String errCode);

    /**
     * 2.9	同步服务报告数据
     *
     * @param reportGuid
     * @param serviceNo
     * @param enginnerId
     * @return java.lang.String
     * @author yzg
     * @date 2020/4/15 1:47 下午
     */
    public String syncServiceReport(String reportGuid, String serviceNo, String enginnerId);

    /**
     * 2.10	同步安装验收数据
     *
     * @param reportGuid
     * @param serviceNo
     * @param enginnerId
     * @return java.lang.String
     * @author yzg
     * @date 2020/4/15 1:47 下午
     */
    public String syncInstallReceivingReport(String reportGuid, String serviceNo, String enginnerId);

    /**
     * 2.11	同步安装质量报告数据
     *
     * @param reportGuid
     * @param serviceNo
     * @param enginnerId
     * @return java.lang.String
     * @author yzg
     * @date 2020/4/15 1:47 下午
     */
    public String syncInstallqualityReport(String reportGuid, String serviceNo, String enginnerId);

    /**
     * 2.65工程师休假状态修改
     *
     * @param enginnerId
     * @param state      1、工作，2、忙碌，3、休假，4、等待备件
     * @methodName: updateFseStateInfo
     * @description: TODO
     * @return: com.alibaba.fastjson.JSONObject
     * @author: shihx
     * @date: 2020-04-21 14:44
     **/
    public JSONObject updateFseStateInfo(String enginnerId, String state) throws Exception;

    /**
     * 2.54查询服务报告数据
     *
     * @methodName: syncAllServiceReport
     * @description: TODO
     * @return: com.ruoyi.system.api.ResponseWithData<?>
     * @author: wlf
     * @date: 2020-04-24 16:51
     **/
    ResponseWithData<?> syncAllServiceReport(String Instrument_id, String starttime, String endtime, String CustName, String SnType, String SnSubType, String SerialNo, String Status);

    /**
     * 2.51获取仪器配置清单接口
     *
     * @param instrumentCode
     * @methodName: getInstrumentFile
     * @description: TODO
     * @return: com.alibaba.fastjson.JSONObject
     * @author: shihx
     * @date: 2020-05-09 8:22
     **/
    public JSONObject getInstrumentFile(String instrumentCode, String serviceNo, String enginnerId);

    /**
     * 2.50获取其他工程师接口
     *
     * @param fseName
     * @param serviceNo
     * @param enginnerId
     * @methodName: getEngineerByName
     * @description: TODO
     * @return: com.ruoyi.system.api.ResponseWithData<?>
     * @author: shihx
     * @date: 2020-05-09 10:33
     **/
    public ResponseWithData<?> getEngineerByName(String fseName, String serviceNo, String enginnerId) throws Exception;

    /**
     * 重写（getEngineerByTL）调用CC端2.6获取TL名下工程师接口更新用户实时数据 重点是：不更新工作状态！！
     *
     * @param serviceNoticeId
     * @param enginnerId
     * @param getFseInformation
     * @author: wlf
     * @date: 2020-05-011 14:48
     */
    public ResponseWithData<?> getEngineerUnupdateWorkday(String serviceNoticeId, String enginnerId, String getFseInformation) throws Exception;

    /**
     * 2.67服务通知同普通费用及特殊费用接口
     *
     * @param serviceNo
     * @methodName: CheckServiceEspecial
     * @description: TODO
     * @return: com.alibaba.fastjson.JSONObject
     * @author: shihx
     * @date: 2020-05-21 10:42
     **/
    public JSONObject CheckServiceEspecial(String serviceNo);


    public JSONObject getStHotAccountReportList(Map<String, String> map);

    public JSONObject getCCErrorReportDetail(Map<String, String> map);

    public JSONObject updatePartsUsedInfo(Map<String, String> map);

    public void deleteCCParts(String partId);

    public void addCCParts(String partId);

    public JSONObject getOtherInstrumentHandle(String instrumentCode, String enginnerId);

    public ResponseWithData<?> selectTransferWithName(String fseName);

    public ResponseWithData<?> selectTransferWithOutName(String fseId);

    public ResponseWithData<?> getTeamSpares(String fseId,String partNo,String status);

    public  String dispatchServicehandle(String sendId,java.util.Date sendDate,String serviceNo,String engineerId);

    public String refuseServicehandle(String engineerId,String serviceNo);
    
    public ResponseWithData<?> getServiceSignPicHandle(String serviceNo);
}
